var e = getApp();

Page({
    data: {
        memberId: 0,
        order: {},
        level: {},
        totalPromotionCount: 0,
        member: {}
    },
    onLoad: function(e) {
        var t = e.member_id;
        this.setData({
            memberId: t
        }), wx.setNavigationBarTitle({
            title: "会员概况"
        }), this.getClients();
    },
    getClients: function() {
        var t = this, r = e.getNetAddresss("plugin.member-center-agent.api.index");
        r += "&member_id=" + this.data.memberId, e._getNetWork({
            url: r,
            success: function(e) {
                var r = e.data, o = r.result, a = r.data, i = r.msg;
                console.log(a), 0 === o && wx.showToast({
                    title: i,
                    icon: "none",
                    duration: 1500,
                    mask: !1,
                    success: function(e) {
                        setTimeout(function() {
                            wx.redirectTo({
                                url: "/packageD/member/myRelationship/myRelationship"
                            });
                        }, 1500);
                    }
                }), a.order.orderCount = Number(a.order.orderCount);
                var n = {
                    level: a.level,
                    order: a.order,
                    totalPromotionCount: a.count,
                    member: a.member
                };
                t.setData(n);
            }
        });
    }
});